/**
 * Classe de gestion des unit�s
 * @author Lo�c Mounier, Thomas Picard, Marianne Grandemenge
 */

package modele;

import java.io.Serializable;
import java.rmi.RemoteException;
import java.rmi.server.UnicastRemoteObject;

import codebase.IUnite;

public abstract class Unite extends UnicastRemoteObject implements Serializable, IUnite {

	private static final long serialVersionUID = 1L;
	private Puissance proprietaire;

	public Unite(Puissance proprietaire) throws RemoteException {
		this.proprietaire = proprietaire;
	}

	public Puissance getProprietaire() {
		return proprietaire;
	}

	public abstract String getTypeUnite();

	public abstract String getTypeUniteAbr();

	public String toString() {
		return "Unite " + this.getTypeUnite() + "appartenant a " + proprietaire.getNom();
	}
}
